package uy.com.tsi2G7.superbet.bet;

import javax.persistence.Column;
import javax.persistence.DiscriminatorValue;
import javax.persistence.Entity;

@Entity
@DiscriminatorValue("SIMPLE")
public class SimpleBet extends Bet{
	
	@Column(name="RESULT")
	private long resultId;
	@Column(name="EVENT")
	private long eventId;
	@Column(name="MARKET")
	private long marketId;
	@Column(name="EVENT_TYPE")
	private long eventTypeId;
	@Column(name="COMPOSITE")
	private boolean composite;
	@Column(name="EVALUATION_RESULT")
    private boolean result = true;//true: se considera que gana si se cumple el resultado, false: se gana si no se cumple el resultado.
	@Column(name="USER_BET")
	private boolean userBet;//Determina si es una apuesta entre usuarios
	
	public SimpleBet() {
		super();
	}
	public SimpleBet(String mail, Long eventType, Long event, Long market,
			Long marketResult) {
		this.marketId=market;
		this.eventId = event;
		this.eventTypeId=eventType;
		this.resultId = marketResult;
		setUserId(mail);
	}
	public long getEventTypeId() {
		return eventTypeId;
	}
	public long getEventId() {
		return eventId;
	}
	public void setEventId(long eventId) {
		this.eventId = eventId;
	}
	public long getMarketId() {
		return marketId;
	}
	public void setMarketId(long marketId) {
		this.marketId = marketId;
	}
	public long getResultId() {
		return resultId;
	}
	public void setResultId(long resultId) {
		this.resultId = resultId;
	}
	public void setEventTypeId(long eventTypeId) {
		this.eventTypeId=eventTypeId;
		
	}
	public boolean isComposite() {
		return composite;
	}
	public void setComposite(boolean composite) {
		this.composite = composite;
	}
	public boolean isResult() {
		return result;
	}
	public void setResult(boolean result) {
		this.result = result;
	}
	public boolean isUserBet() {
		return userBet;
	}
	public void setUserBet(boolean userBet) {
		this.userBet = userBet;
	}


}
